/*
 * =====================================================================================
 *
 *       Filename:  float_add.cpp
 *
 *    Description:  
 *
 *        Version:  1.0
 *        Created:  03/20/2018 06:20:56 PM
 *       Revision:  none
 *       Compiler:  gcc
 *
 *         Author:  YOUR NAME (), 
 *   Organization:  
 *
 * =====================================================================================
 */
#include <stdlib.h>
#include <math.h>
#include <stdio.h>

int main(int argc, char** argv)
{
    int result = 0;
    float result_f = 0;
    int money = 18;
    int items_count = 7;
    printf("argc[%d]", argc);
    for (int i = 0; i < argc; ++i)
    {
        result += (float)money * (float)items_count * 0.3;
        result_f += money * items_count * 0.3;
    }
    printf("result[%d] result_f[%f] result_f[%d]\n", result, result_f, floor(result_f));

    return 0;
}
